#Boa:Frame:NewAccoutsFrame

import wx
from wx.lib.anchors import LayoutAnchors

def create(parent):
    return NewAccoutsFrame(parent)

[wxID_NEWACCOUTSFRAME, wxID_NEWACCOUTSFRAMECANCELBUTTON, 
 wxID_NEWACCOUTSFRAMESAVEBUTTON, wxID_NEWACCOUTSFRAMESTATICTEXT1, 
 wxID_NEWACCOUTSFRAMESTATICTEXT2, wxID_NEWACCOUTSFRAMETEXTCTRL1, 
 wxID_NEWACCOUTSFRAMETEXTCTRL2, 
] = [wx.NewId() for _init_ctrls in range(7)]

class NewAccoutsFrame(wx.Frame):
    def _init_coll_flexGridSizer1_Items(self, parent):
        # generated method, don't edit

        parent.AddWindow(self.staticText1, 1, border=0,
              flag=wx.ALIGN_CENTER_VERTICAL | wx.ALIGN_CENTER_HORIZONTAL)
        parent.AddWindow(self.staticText2, 1, border=0,
              flag=wx.ALIGN_CENTER_VERTICAL | wx.ALIGN_CENTER_HORIZONTAL)
        parent.AddWindow(self.textCtrl1, 3, border=0,
              flag=wx.ALIGN_TOP | wx.ALIGN_CENTER_HORIZONTAL)
        parent.AddWindow(self.textCtrl2, 1, border=0,
              flag=wx.ALIGN_TOP | wx.ALIGN_CENTER_HORIZONTAL)
        parent.AddWindow(self.CancelButton, 1, border=0,
              flag=wx.ALIGN_CENTER_HORIZONTAL)
        parent.AddWindow(self.SaveButton, 1, border=0,
              flag=wx.ALIGN_CENTER_HORIZONTAL)

    def _init_coll_flexGridSizer1_Growables(self, parent):
        # generated method, don't edit

        parent.AddGrowableRow(0)
        parent.AddGrowableRow(1)
        parent.AddGrowableRow(2)
        parent.AddGrowableCol(0)
        parent.AddGrowableCol(1)

    def _init_sizers(self):
        # generated method, don't edit
        self.flexGridSizer1 = wx.FlexGridSizer(cols=2, hgap=0, rows=3, vgap=0)

        self._init_coll_flexGridSizer1_Items(self.flexGridSizer1)
        self._init_coll_flexGridSizer1_Growables(self.flexGridSizer1)

        self.SetSizer(self.flexGridSizer1)

    def _init_ctrls(self, prnt):
        # generated method, don't edit
        wx.Frame.__init__(self, id=wxID_NEWACCOUTSFRAME, name='NewAccoutsFrame',
              parent=prnt, pos=wx.Point(832, 401), size=wx.Size(474, 253),
              style=wx.DEFAULT_FRAME_STYLE, title='New Account')
        self.SetClientSize(wx.Size(464, 200))

        self.staticText1 = wx.StaticText(id=wxID_NEWACCOUTSFRAMESTATICTEXT1,
              label='Account Name', name='staticText1', parent=self,
              pos=wx.Point(76, 18), size=wx.Size(136, 32), style=0)
        self.staticText1.Center(wx.HORIZONTAL)

        self.staticText2 = wx.StaticText(id=wxID_NEWACCOUTSFRAMESTATICTEXT2,
              label='Opening Balance', name='staticText2', parent=self,
              pos=wx.Point(308, 18), size=wx.Size(136, 32), style=0)
        self.staticText2.Center(wx.HORIZONTAL)

        self.textCtrl1 = wx.TextCtrl(id=wxID_NEWACCOUTSFRAMETEXTCTRL1,
              name='textCtrl1', parent=self, pos=wx.Point(20, 68),
              size=wx.Size(248, 27), style=0, value='textCtrl1')

        self.textCtrl2 = wx.TextCtrl(id=wxID_NEWACCOUTSFRAMETEXTCTRL2,
              name='textCtrl2', parent=self, pos=wx.Point(326, 68),
              size=wx.Size(100, 27), style=0, value='textCtrl2')

        self.CancelButton = wx.Button(id=wxID_NEWACCOUTSFRAMECANCELBUTTON,
              label='Cancel', name='CancelButton', parent=self, pos=wx.Point(94,
              131), size=wx.Size(100, 33), style=0)
        self.CancelButton.Bind(wx.EVT_BUTTON, self.OnCancelButtonButton,
              id=wxID_NEWACCOUTSFRAMECANCELBUTTON)

        self.SaveButton = wx.Button(id=wxID_NEWACCOUTSFRAMESAVEBUTTON,
              label='Save', name='SaveButton', parent=self, pos=wx.Point(326,
              131), size=wx.Size(100, 33), style=0)

        self._init_sizers()

    def __init__(self, parent):
        self._init_ctrls(parent)

    def OnCancelButtonButton(self, event):
        self.Close(True)
